#include <iostream>
#include <string>
#include <vector>
#include <map>
#include <random>
#include <algorithm>


#define _CRT_SECURE_NO_WARNINGS
using namespace std;


#define SALE_DEPATMENT 1  //分别是销售部门，研发部门，财务部门，所有部门。
#define DEVELOP_DEPARTMENT 2
#define FINACTIAL_DEPARTMENT 3
#define ALL_DEPARTMENT 4

class person
{
    public:
    person(string Name,int Age,double Salary,string Tele){
        name=Name,age=Age,salary=Salary,tele=Tele;
        };
    ~person(){};

   inline void GetInformation(){cout<<"NAME: "<<name<<endl<<"AGE: "<<age<<endl<<"SALARY: "<<salary<<endl<<"TELE: "<<tele<<endl;}

    private:
        string name;
        int age;
        double salary;
        string tele;


};


//创建员工信息
void CreatePerson(vector<person> &vlist){
    string seed="ABCDE";
    for(int i=0;i<5;i++){

        string originName="zhang"+seed[i];
        
        int age=rand()%30+20;
        int salary = rand() % 20000 + 10000;

        person p1(originName,age,salary,"010-8888888");
        vlist.push_back(p1);
    }
}

void printInformation(vector<person> vlist){
    for(vector<person>::iterator it=vlist.begin();it!=vlist.end();it++)
    {
        it->GetInformation();
    }
}

//主函数，用于输出计算
int main(int argc, char **argv)
{
    vector<person> vlist;//初始化一个person类的容器；
    CreatePerson(vlist); //创建员工
    printInformation(vlist);
    cout<<"this is main function"<<endl;
}